
<script setup>
import { getMyBookList } from '@/api/book/index.js'
import { onMounted, reactive, ref } from 'vue'
import { useRouter } from 'vue-router'
let activeKey = ref('1')
const router = useRouter()

// 章节管理

// 上传章节
const uploadChapter = (title, no, id) => {
  router.push({path: '/book/chapter/upload', query: { title, chapter: no + 1, novelId: id} })
}

const handleChange = (key) => {
  if (key === '1') {

  } else if (key === '2') {
    uploadChapter()
  } else {

  }
}
</script>
<template>
  <a-tabs v-model:activeKey="activeKey" size="large" @tabClick="handleChange">
    <a-tab-pane key="1" tab="章节管理"></a-tab-pane>
    <a-tab-pane key="2" tab="上传章节"></a-tab-pane>
    <a-tab-pane key="3" tab="草稿箱"></a-tab-pane>
  </a-tabs>
  <router-view></router-view>
</template>

<style lang="less" scoped>

</style>